from django.db import models

# Create your models here.


class Notification(models.Model):
    """消息公告表"""
    id = models.BigAutoField(primary_key=True)
    title = models.CharField(max_length=200, verbose_name="通知标题")
    content = models.TextField(verbose_name="通知内容")
    expired_time = models.DateTimeField(verbose_name="失效时间")
    is_show = models.BooleanField(verbose_name="是否展示", default=False)
    create_time = models.DateTimeField(auto_now_add=True, verbose_name="创建时间")
    modified_time = models.DateTimeField(auto_now=True, verbose_name="修改时间")

    class Meta:
        verbose_name = "公告"
        verbose_name_plural = "公告管理"
        db_table = "tbl_notification"
